*Cloud plot*

clear


use "Results\fig_A1\dataset_with_singles_LFS_short_irreg_50_primeage.dta"

keep if aar==2018
drop if final_educ==. | final_educ==1
sort final_educ

by final_educ: egen level_mean_s=mean(wage_start_mean_ambition_s)
by final_educ: egen growth_mean_s=mean(wage_growth_ambition_s)
by final_educ: egen educ_count=count(final_educ)

by final_educ: egen short_mean_s=mean(short_hours_100_s)
by final_educ: egen irreg_mean_s=mean(irreg_50_s)



collapse (first) level_mean_s growth_mean_s educ_count ambition_type_k_4_s ambition_short_irreg_50 short_mean_s irreg_mean_s, by(final_educ)

gen educ_code=string(final_educ)

*Plots

*Fig A2c

twoway scatter growth_mean_s level_mean_s if ambition_short_irreg_50==3 & educ_count>=10, msymbol(diamond_hollow) mcolor(teal) || ///
scatter growth_mean_s level_mean_s if ambition_short_irreg_50==4 & educ_count>=10, msymbol(square_hollow) mcolor(navy) || /// 
scatter growth_mean_s level_mean_s if ambition_short_irreg_50==1 & educ_count>=10, msymbol(triangle_hollow) mcolor(dkorange) || ///
scatter growth_mean_s level_mean_s if ambition_short_irreg_50==2 & educ_count>=10, msymbol(circle_hollow) mcolor(maroon) ///
xtitle("starting wage (standardized)") ytitle("growth (standardized)") ///
legend(order(1 "high short, mid irreg" 2 "low short, low irreg" 3 "mid short, low irreg" 4 "low short, high irreg") position(6) cols(2) rows(2)) graphregion(fcolor(white)) xscale(range(-2 6)) xlabel(-2(2)6) yscale(range(-5 5.5)) ylabel(-5(5)5)


*Fig A1a

twoway scatter irreg_mean_s short_mean_s if ambition_short_irreg_50==3 & educ_count>=10, msymbol(diamond_hollow) mcolor(teal) || ///
scatter irreg_mean_s short_mean_s if ambition_short_irreg_50==4 & educ_count>=10, msymbol(square_hollow) mcolor(navy) || ///
scatter irreg_mean_s short_mean_s if ambition_short_irreg_50==1 & educ_count>=10, msymbol(triangle_hollow) mcolor(dkorange) || ///
scatter irreg_mean_s short_mean_s if ambition_short_irreg_50==2 & educ_count>=10, msymbol(circle_hollow) mcolor(maroon) ///
xtitle("share with short hours (standardized)") ytitle("share with irregular hours (standardized)") ///
legend(order(1 "high short, mid irreg" 2 "low short, low irreg" 3 "mid short, low irreg" 4 "low short, high irreg") position(6) cols(2) rows(2)) graphregion(fcolor(white)) xscale(range(-2 4)) xlabel(-2(2)4) yscale(range(-5 5)) ylabel(-5(5)5)




gen program_name=""

replace program_name="Preschool teacher" if educ_code=="5444" /*Health*/
replace program_name="Nurse" if educ_code=="5166" /*Health*/
replace program_name="Medicin" if educ_code=="7170" /*Health*/
replace program_name="Ordinary HS" if educ_code=="1198" /*Secondary*/
replace program_name="Carpenter" if educ_code=="4283" /*Secondary*/
replace program_name="Office clerk" if educ_code=="4981" /*Secondary*/
replace program_name="Business HS" if educ_code=="5098" /*Secondary*/
replace program_name="Bank advisor" if educ_code=="4986" /*Secondary*/
replace program_name="Teacher" if educ_code=="5440" /*Humanities*/
replace program_name="Architect" if educ_code=="5470" /*STEM NOT one of biggest*/
replace program_name="10th grade" if educ_code=="111084" /*Primary*/
replace program_name="Business grad" if educ_code=="5703" /*Business*/
replace program_name="Business bach" if educ_code=="5700" /*Business*/
replace program_name="Law" if educ_code=="7085" /*Social Science*/
replace program_name="Painter" if educ_code=="4274"

tab program_name ambition_short_irreg_50

*Fig A1b

twoway scatter irreg_mean_s short_mean_s if inlist(educ_code, "5444"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "5440"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "4981"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(6) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "5703"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(11) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "1198"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "5166"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(6) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "4283"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(6) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code,"5470"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "5098"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "111084"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "4986"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(9) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "5700"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(8) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code,"7170"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(8) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code,"7085"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter irreg_mean_s short_mean_s if inlist(educ_code, "4274"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(5) ///
xtitle("share with short hours (standardized)") ytitle("share with irregular hours (standardized)") ///
legend(order(1 "high short, mid irreg" 7 "low short, low irreg" 3 "mid short, low irreg" 2 "low short, high irreg") position(6) cols(2) rows(2)) graphregion(fcolor(white)) xscale(range(-2 4)) xlabel(-2(2)4) yscale(range(-5 5)) ylabel(-5(5)5)


*Fig A2d

twoway scatter growth_mean_s level_mean_s if inlist(educ_code, "5444"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(7) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5440"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4981"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5703"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "1198"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(9) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5166"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4283"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code,"5470"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5098"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "111084"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(10) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4986"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(9) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5700"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code,"7170"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code,"7085"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4274"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(4) ///
xtitle("share with short hours (standardized)") ytitle("share with irregular hours (standardized)") ///
legend(order(1 "high short, mid irreg" 7 "low short, low irreg" 3 "mid short, low irreg" 2 "low short, high irreg") position(6) cols(2) rows(2)) graphregion(fcolor(white)) xscale(range(-2 4)) xlabel(-2(2)4) yscale(range(-5 5)) ylabel(-5(5)5)



*Fig A2b

twoway scatter growth_mean_s level_mean_s if inlist(educ_code, "4274"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(5) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5440"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4981"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5703"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5166"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4283"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code,"5470"), msymbol(square_hollow) mcolor(navy) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5098"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "1198"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(9) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "111084"),  msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(12) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "4986"), msymbol(triangle_hollow) mcolor(dkorange) ///
mlab(program_name) mlabc(black) mlabposition(3) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5700"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code, "5444"), msymbol(diamond_hollow) mcolor(teal) ///
mlab(program_name) mlabc(black) mlabposition(7) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code,"7170"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(1) || ///
scatter growth_mean_s level_mean_s if inlist(educ_code,"7085"), msymbol(circle_hollow) mcolor(maroon) ///
mlab(program_name) mlabc(black) mlabposition(12) ///
xtitle("starting wage (standardized)") ytitle("growth (standardized)") ///
legend(order(1 "low w{sub:0}, low g" 2 "high w{sub:0}, low g" 3 "low w{sub:0}, high g" 4 "high w{sub:0}, high g") position(6) cols(2) rows(2)) graphregion(fcolor(white)) xscale(range(-2 4)) xlabel(-2(2)4) yscale(range(-5 5)) ylabel(-5(5)5)

graph export "Results\fig_A1\cloud_benchmark_space_examples_ambition.pdf", replace
